Skip to main content
WebsiteGitHub last commitGitHub commit activityGitHub IssuesDocker PullsDiscordLocalized

Creating a Local Admin Account via CMD

Creating a local administrator account gives you a fallback login that is independent of your Microsoft Account and any Microsoft services. This is especially useful before making changes that could affect Microsoft Account authentication (such as disabling wlidsvc or blocking login.live.com).

warning

You must run Command Prompt as Administrator for these commands to work. Right-click the Start menu → Terminal (Admin) or search for cmd, right-click → Run as administrator.

Step 1 — Create the User Account

net user /add [username] [password]

Replace [username] with your chosen account name and [password] with a strong password.

Example:

net user /add LocalAdmin MyStr0ngP@ss!
tip

Avoid spaces in the username. If you need spaces, wrap the username in quotes: net user /add "My Admin" password.

Step 2 — Add the Account to the Administrators Group

net localgroup administrators [username] /add

Example:

net localgroup administrators LocalAdmin /add

This grants the new account full administrative privileges on the local machine.

Step 3 — Verify the Account

Confirm the account was created and is in the Administrators group:

net user [username]

Look for Local Group Memberships in the output — it should include *Administrators.

You can also list all members of the Administrators group:

net localgroup administrators

Signing In with the New Account

Once created, the account will appear on the Windows login screen. You can switch to it without restarting:

  1. Press Win + L to lock the screen
  2. Click on the new username in the bottom-left corner of the login screen
  3. Enter the password you set in Step 1

Setting a Password (Optional — If You Want No Password)

caution

Passwordless local accounts are a security risk, especially on shared or portable machines.

To create an account with no password, omit the password argument:

net user /add [username]

Removing the Account (Cleanup)

If you no longer need the local account, you can remove it:

net user /delete [username]

Buy me a beer

Changelog

docs(windows): add Privacy section with GDID guide and Local Admin Account doc


💬 Discord Community Chat

Join the conversation! Comments here sync with our Discord community.

💬 Recent Comments

Loading comments...